home *** CD-ROM | disk | FTP | other *** search
/ Whiteline: Alpha / Whiteline Alpha.iso / tools / prtfolio / port_2 / basic / kniffel.bas < prev    next >
Encoding:
BASIC Source File  |  1994-09-22  |  3.1 KB  |  112 lines

  1. rem für Portfolio von R.Rumrich
  2. 1 randomize
  3.  cls: dim w(5),z(4,17)
  4.  BOX 1,14,5,24,1:locate 3,16:Print "KNIFFEL"
  5. 2 wait:cls: gosub 2000
  6.  n=0:r=0
  7. 6 n=n+1: if n>13 then 3000
  8.  for a = 1 to s
  9.  gosub 1000
  10.  w(1) =x: gosub 1000
  11.  w(2) =x: gosub 1000
  12.  w(3) =x: gosub 1000
  13.  w(4) =x: gosub 1000
  14.  w(5) =x
  15. 55 cls:r=r+1
  16. 60 BOX 2,17,4,19,1:BOX 2,22,4,24,1:BOX 2,27,4,29,1:BOX 2,32,4,34,1:BOX 2,37,4,39,1
  17.    locate 3,18:print w(1):locate 3,23:print w(2):locate 3,28:print w(3)
  18.    locate 3,33:print w(4):locate 3,38:print w(5)
  19.     locate 3,1:print"Wurf ";r;" !":gosub 500:goto 70
  20. 500 locate 2,1:print n$(a)
  21.  locate 5,1: print "1er";z(a,1);" 2er";z(a,2);" 3er";z(a,3);
  22.  print " 4er";z(a,4);" 5er";z(a,5);" 6er";z(a,6)
  23.  print "TOT";;z(a,14);" BON";z(a,15);" TTO";z(a,16)
  24.  print "DRP";z(a,7);" VIP";z(a,8);" FUL";z(a,9);" KLS";z(a,10);
  25.  print " GRS";z(a,11);" XKX";z(a,12)
  26.  print "CHA";z(a,13);"       TTU";z(a,17);" TTO";z(a,16);" GES";z(a,0)
  27.  return
  28. 70 a$=inkey$: if a$ = "" then goto 70
  29.  if r=3 then 100
  30.  if a$="1" then w(1)=x:goto 1500
  31.  if a$="2" then w(2)=x:goto 1500
  32.  if a$="3" then w(3)=x:goto 1500
  33.  if a$="4" then w(4)=x:goto 1500
  34.  if a$="5" then w(5)=x:goto 1500
  35.  if a$="w" then 55
  36. 100 if a$="e" then print "Eintrag ";:goto 600
  37.   goto 70
  38. 600 p$=inkey$:if p$="" then 600
  39.  if p$="1" then 810
  40.  if p$="2" then 820
  41.  if p$="3" then 830
  42.  if p$="4" then 840
  43.  if p$="5" then 850
  44.  if p$="6" then 860
  45.  if p$="d" then 870
  46.  if p$="v" then 873
  47.  if p$="f" then 876
  48.  if p$="k" then 880
  49.  if p$="g" then 884
  50.  if p$="x" then 888
  51.  if p$="c" then 895
  52.  goto 600
  53. 650 r=0: next a
  54.  goto 6
  55. 700 z(a,14)=z(a,1)+z(a,2)+z(a,3)+z(a,4)+z(a,5)+z(a,6)
  56.  z(a,17)=z(a,7)+z(a,8)+z(a,9)+z(a,10)+z(a,11)+z(a,12)+z(a,13)
  57.  for i = 1 to 6
  58.  if z(a,i)=100 then z(a,14)=z(a,14)-100
  59.  next i
  60.  for i = 7 to 13
  61.  if z(a,i)=100 then z(a,17)=z(a,17)-100
  62.  next i
  63.  if z(a,14)>62 then z(a,15)=35
  64.  z(a,16)=z(a,14)+z(a,15)
  65.  z(a,0)=z(a,16)+z(a,17)
  66. cls:gosub 500:wait:goto 650
  67. 810 if z(a,1)>=1 then 900
  68.  input "1er ",z(a,1):goto 700
  69. 820 if z(a,2)>1 then 900
  70.  input "2er ",z(a,2):goto 700
  71. 830 if z(a,3)>1 then 900
  72.  input "3er ",z(a,3):goto 700
  73. 840 if z(a,4)>1 then 900
  74.  input "4er ",z(a,4):goto 700
  75. 850 if z(a,5)>1 then 900
  76.  input "5er ",z(a,5):goto 700
  77. 860 if z(a,6)>1 then 900
  78.  input "6er ",z(a,6):goto 700
  79. 870 if z(a,7)>1 then 900
  80.  input "Dreier Pasch ",z(a,7):goto 700
  81. 873 if z(a,8)>1 then 900
  82.  input "Vierer Pasch ",z(a,8):goto 700
  83. 876 if z(a,9)>1 then 900
  84.  input "Full House=25 ",z(a,9):goto 700
  85. 880 if z(a,10)>1 then 900
  86.  input "Kl Straβe=30 ",z(a,10):goto 700
  87. 884 if z(a,11)>1 then 900
  88.  input "Gr Straβe=40 ",z(a,11):goto 700
  89. 888 if z(a,12)>1 then 900
  90.  input "Kniffel=50 ",z(a,12):goto 700
  91. 895 if z(a,13)>1 then 900
  92.  z(a,13)=w(1)+w(2)+w(3)+w(3)+w(4)+w(5):goto 700
  93. 900 print "Besetzt!";:wait:goto 600
  94. 1000 x=int(rnd*6)+1:return
  95. 1500 x=int(rnd*6)+1:goto 70
  96. 2000 input "Wieviele Spieler? ",s
  97.  dim n$(s)
  98.  for a=1 to s
  99.  input "Name: ",n$(a)
  100.  next a
  101.  return
  102. 3000 for a=1 to s
  103.  print n$(a);" hat ";z(a,0);" punkte"
  104.  next a
  105.  print "Noch ein spiel? J/N";
  106. 3032 p$=inkey$:if p$="" then 3032
  107.  if p$="J" then 1
  108.  cls: print "Bis zum nächsten Mal!": end
  109.  
  110.  
  111. ə
  112.